import EnterpriseAdminExtensionAbility from '@ohos.EnterpriseAdminExtensionAbility';
import Logger from '../common/logger'
export default class EnterpriseAdminAbility extends EnterpriseAdminExtensionAbility {
    static countEnable: number = 0;
    static countDisable: number = 0;
    onAdminEnabled() {
        // Ability has back to background
        EnterpriseAdminAbility.countEnable++;
        EnterpriseAdminAbility.countDisable++;
        Logger.info("EnterpriseAdminAbility", "onAdminEnabled countEnable=" + EnterpriseAdminAbility.countEnable +
        ' | countDisable=' + EnterpriseAdminAbility.countDisable)
    }

    onAdminDisabled() {
        // Ability has back to background
        EnterpriseAdminAbility.countEnable++;
        EnterpriseAdminAbility.countDisable++;
        Logger.info("EnterpriseAdminAbility", "onAdminDisabled countEnable=" + EnterpriseAdminAbility.countEnable +
        ' | countDisable=' + EnterpriseAdminAbility.countDisable)
    }
};